<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <title>basic svg lighting 💡</title>
    <link rel="stylesheet" href="style.css">

</head>

<body>
<div class="icon" data-light="light1">
    <img src="https://assets.codepen.io/605876/spotify.png" alt="spotify"/>
</div>
<div class="icon" data-light="light2">
    <img src="https://assets.codepen.io/605876/raycast.png" alt="raycast"/>
</div>
<div class="icon" data-light="light3">
    <img src="https://assets.codepen.io/605876/discord.png" alt="discord"/>
</div>
<div class="icon" data-light="light4">
    <img
            src="https://assets.codepen.io/605876/screenstudio.png"
            alt="screen studio"
    />
</div>
<article class="surface">
    <nav>
        <div></div>
        <div></div>
        <div></div>
    </nav>
    <svg class="filter" xmlns="http://www.w3.org/2000/svg">
        <filter
                id="lighting"
                filterUnits="objectBoundingBox"
                x="0%"
                y="0%"
                width="100%"
                height="100%"
        >
            <!-- Light source 1 -->
            <feSpecularLighting
                    in="SourceAlpha"
                    result="light1"
                    id="light1"
                    specularConstant="12"
                    specularExponent="120"
                    lighting-color="hsl(142 77% 48%)"
                    surfaceScale="1"
            >
                <fePointLight x="-50" y="50" z="180"/>
            </feSpecularLighting>
            <feSpecularLighting
                    in="SourceAlpha"
                    result="light2"
                    id="light2"
                    specularConstant="1"
                    specularExponent="20"
                    surfaceScale="1"
                    lighting-color="hsl(0 100% 69%)"
            >
                <fePointLight x="250" y="50" z="180"/>
            </feSpecularLighting>

            <feSpecularLighting
                    in="SourceAlpha"
                    result="light3"
                    id="light3"
                    specularConstant="1"
                    specularExponent="20"
                    surfaceScale="1"
                    lighting-color="hsl(235 86% 73%)"
            >
                <fePointLight x="250" y="50" z="180"/>
            </feSpecularLighting>
            <feSpecularLighting
                    in="SourceAlpha"
                    result="light4"
                    id="light4"
                    specularConstant="1"
                    specularExponent="20"
                    surfaceScale="1"
                    lighting-color="hsl(267 61% 48%)"
            >
                <fePointLight x="250" y="50" z="180"/>
            </feSpecularLighting>
            <!-- Blend lights pair by pair -->
            <feBlend in="light1" in2="light2" mode="screen" result="blend12"/>
            <feBlend in="light3" in2="light4" mode="screen" result="blend34"/>
            <feBlend
                    in="blend12"
                    in2="blend34"
                    mode="screen"
                    result="allLights"
            />

            <!-- Apply lighting over shape -->
            <feComposite
                    in="allLights"
                    in2="SourceGraphic"
                    operator="in"
                    result="litShape"
            />
            <feMerge>
                <feMergeNode in="litShape"/>
            </feMerge>
        </filter>
    </svg>
</article>
<a
        aria-label="Follow Jhey"
        class="bear-link"
        href="https://twitter.com/intent/follow?screen_name=jh3yy"
        target="_blank"
        rel="noreferrer noopener"
>
    <svg
            class="w-9"
            viewBox="0 0 969 955"
            fill="none"
            xmlns="http://www.w3.org/2000/svg"
    >
        <circle
                cx="161.191"
                cy="320.191"
                r="133.191"
                stroke="currentColor"
                stroke-width="20"
        ></circle>
        <circle
                cx="806.809"
                cy="320.191"
                r="133.191"
                stroke="currentColor"
                stroke-width="20"
        ></circle>
        <circle
                cx="695.019"
                cy="587.733"
                r="31.4016"
                fill="currentColor"
        ></circle>
        <circle
                cx="272.981"
                cy="587.733"
                r="31.4016"
                fill="currentColor"
        ></circle>
        <path
                d="M564.388 712.083C564.388 743.994 526.035 779.911 483.372 779.911C440.709 779.911 402.356 743.994 402.356 712.083C402.356 680.173 440.709 664.353 483.372 664.353C526.035 664.353 564.388 680.173 564.388 712.083Z"
                fill="currentColor"
        ></path>
        <rect
                x="310.42"
                y="448.31"
                width="343.468"
                height="51.4986"
                fill="#FF1E1E"
        ></rect>
        <path
                fill-rule="evenodd"
                clip-rule="evenodd"
                d="M745.643 288.24C815.368 344.185 854.539 432.623 854.539 511.741H614.938V454.652C614.938 433.113 597.477 415.652 575.938 415.652H388.37C366.831 415.652 349.37 433.113 349.37 454.652V511.741L110.949 511.741C110.949 432.623 150.12 344.185 219.845 288.24C289.57 232.295 384.138 200.865 482.744 200.865C581.35 200.865 675.918 232.295 745.643 288.24Z"
                fill="currentColor"
        ></path>
    </svg>
</a>
<script type="module" src="script.js"></script>

</body>

</html>
